/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package pfc.modelocg;

import pfc.modelocg.CGForm.FormType;

/**
 *
 * @author xandru
 */
public class CGEntityForms {

    String _entityName;
    Boolean generateEditForm=true;
    Boolean generateLinesForm=true;
    Boolean generateSearchForm=true;
    Boolean generateLinkedForms=true;
    CGModel _modelo;

    CGEntityForms(CGModel m, String entityName)
    {
        this._entityName = entityName;
        this._modelo = m;
    }

    public String getEntityName() {
        return _entityName;
    }

    public void setEntityName(String _entityName) {
        this._entityName = _entityName;
    }

    public Boolean isGenerateEditForm() {
        return generateEditForm;
    }

    public void setGenerateEditForm(boolean generateEditForm) {
        this.generateEditForm = generateEditForm;

        if (generateEditForm == false)
        {
            this._modelo.removeForm(this._entityName,FormType.EditForm);
        }
    }

    public Boolean isGenerateLinesForm() {
        return generateLinesForm;
    }

    public void setGenerateLinesForm(boolean generateLinesForm) {
        this.generateLinesForm = generateLinesForm;
    }

    public Boolean isGenerateLinkedForms() {
        return generateLinkedForms;
    }

    public void setGenerateLinkedForms(boolean generateLinkedForms) {
        this.generateLinkedForms = generateLinkedForms;
    }

    public Boolean isGenerateSearchForm() {
        return generateSearchForm;
    }

    public void setGenerateSearchForm(boolean generateSearchForm) {
        this.generateSearchForm = generateSearchForm;
    }


}
